# coding=utf-8

import D2Ext


class CGame(object):

    @staticmethod
    def SpawnMonster(ptGame, ptRoom, zero1, x, y, minusOne, superuniqueID, zero2):
        return D2Ext.Game_SpawnMonster(ptGame, ptRoom, zero1, x, y, minusOne, superuniqueID, zero2)

    @staticmethod
    def SpawnSuperUniqueMonster(ptGame, ptRoom, x, y, superuniqueID):
        return D2Ext.Game_SpawnSuperUniqueMonster(ptGame, ptRoom, x, y, superuniqueID)

    @staticmethod
    def DropTreasureClass(ptGame, ptSource, ptKiller, ptTC_D2TCExShortStrc, nQuality, nIlvl, dwZero, dwZero2, dwZero3, dwZero4):
        return D2Ext.Game_DropTreasureClass(ptGame, ptSource, ptKiller, ptTC_D2TCExShortStrc, nQuality, nIlvl, dwZero, dwZero2, dwZero3, dwZero4)

    @staticmethod
    def DeleteItem(ptGame, ptPlayer, pItem):
        return D2Ext.Game_DeleteItem(ptGame, ptPlayer, pItem)

    @staticmethod
    def SpawnItem(ptGame, ptUnit, dwCode, nItemLevel, nQuality, bDrop):
        return D2Ext.Game_SpawnItem(ptGame, ptUnit, dwCode, nItemLevel, nQuality, bDrop)

    @staticmethod
    def GetObject(ptGame, unit_type, unit_id):
        return D2Ext.Game_GameGetObject(ptGame, unit_type, unit_id)

    @staticmethod
    def UpdateClientItemStat(ptClient, ptItem, bSetStat, nStat, nValue):
        return D2Ext.Game_SpawnMonster(ptClient, ptItem, bSetStat, nStat, nValue)

    @staticmethod
    def UpdateSkills(ptClient, ptPlayer, SkillID, dwZero, dwOne):
        return D2Ext.Game_UpdateSkills(ptClient, ptPlayer, SkillID, dwZero, dwOne)

    @staticmethod
    def GetPlayerPet(ptPlayer, ptGame):
        return D2Ext.Game_GetPlayerPet(ptPlayer, ptGame)

    @staticmethod
    def GetPlayerFromPet(ptGame, ptMonsterBeHitted, ptCheckMonster):
        return D2Ext.Game_GetPlayerFromPet(ptGame, ptMonsterBeHitted, ptCheckMonster)

    @staticmethod
    def SendMsgToServer(size, one, data):
        return D2Ext.Game_SendMsgToServer(size, one, data)

    @staticmethod
    def SendMsgToServer3(data):  # data 数值小于65536
        return D2Ext.Game_SendMsgToServer3(data)

    @staticmethod
    def SendMsgToClient(ptClient, data, nSize):
        return D2Ext.Game_SendMsgToClient(ptClient, data, nSize)
